package lab02.test03;

public class Student {

    float math;
    float english;
    float computer;

    Student() {
    }

    float sum() {
        return math + english + computer;
    }

    float average() {
        return (math + english + computer) / 3;
    }
//未完成学生那门课的成绩最高最低
    float max() {
        float max = math;

        max = math > english ? math : english;
        max = max > computer ? max : computer;
        return max;
    }

    float min() {
        float min;

        min = math < english ? math : english;
        min = min < computer ? min : computer;
        return min;
    }
//打印成绩
    void printGarde() {
        System.out.println("math：" + math + "\t" + " english" + english + "\t"
                + " computer :" + computer);
    }
}
